package user_detail

import (
	"github.com/bgmp/config"
	"github.com/bgmp/handler"
	"github.com/bgmp/model"
	"github.com/gin-gonic/gin"
	log "github.com/sirupsen/logrus"
)

func (b Base) AddUserDetail(c *gin.Context, req *model.UserDetail) *AddUserDetailResponse {

	err := req.Create(config.DB)
	if err != nil {
		handler.Errorf(c, "添加记录失败")
		log.Error(err)
		return nil
	}

	return &AddUserDetailResponse{}
}

// VO
type AddUserDetailResponse struct {
}
